package com.todo.common.common.constants;

/**
 * 通用常量信息
 */
public interface Constants {

    /**
     * UTF-8 字符集
     */
    String UTF8 = "UTF-8";

    /**
     * GBK 字符集
     */
    String GBK = "GBK";

    /**
     * www主域
     */
    String WWW = "www.";

    /**
     * http请求
     */
    String HTTP = "http://";

    /**
     * https请求
     */
    String HTTPS = "https://";

    /**
     * 注册
     */
    String REGISTER = "Register";

    /**
     * 登录失败
     */
    String LOGIN_FAIL = "Error";

    /**
     * 令牌
     */
    String TOKEN = "token";

    /**
     * 令牌前缀
     */
    String TOKEN_PREFIX = "Bearer ";

    /**
     * 令牌前缀
     */
    String LOGIN_USER_KEY = "login:user_key:%s";
    String LOGIN_STAFF_KEY = "login:staff_key:%s";
    String LOGIN_CAPTCHA_KEY = "login:captcha_key:%s";

    /**
     * 当前用户
     */
    String CURRENT_USER = "currentUser";
    /**
     * 链路Id
     */
    String TRACE_ID = "traceId";

    /**
     * 默认登陆缓存时常
     */
    long LOGIN_USER_EXPIRE = 60 * 60 * 24 * 7;
}

